package com.atguigu.gmall.product.controller;

import com.atguigu.gmall.common.result.Result;
import com.atguigu.gmall.product.service.RedisTestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.cache.CacheProperties;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 搭忆长安
 * @version 1.0
 * @date 2021年07月02日 16:13
 * @ClassName:RedisTestController
 * @Description: TODO
 */
@RestController
@RequestMapping(value = "/redis/product/test")
public class RedisTestController {
    @Autowired
    private RedisTestService redisTestService;

    @GetMapping(value = "/demo1")
    public Result demo1(){
        redisTestService.lockDemo3();
        return Result.ok();
    }
}
